<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org"
      xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">

    <meta name="_csrf" th:content="${_csrf.token}"/>
    <meta name="_csrf_header" th:content="${_csrf.headerName}"/>
    <title>Dashboard - PixelAdmin</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">

    <!-- Open Sans font from Google CDN -->

    <!-- Pixel Admin's stylesheets -->
    <link href="/assets/stylesheets/bootstrap.min.css" rel="stylesheet" type="text/css">
    <link href="/assets/stylesheets/pixel-admin.min.css" rel="stylesheet" type="text/css">
    <link href="/assets/stylesheets/widgets.min.css" rel="stylesheet" type="text/css">
    <link href="/assets/stylesheets/rtl.min.css" rel="stylesheet" type="text/css">
    <link href="/assets/stylesheets/themes.min.css" rel="stylesheet" type="text/css">
    <!--[if lt IE 9]>
    <script src="/assets/javascripts/ie.min.js"></script>
    <![endif]-->

    <!-- Get jQuery from Google CDN -->
    <script src="/assets/javascripts/jquery-1.10.2.min.js"></script>
</head>

<body class="theme-default main-menu-animated">
<script>var init = [];</script>


<!-- 2. $MAIN_NAVIGATION ===========================================================================

	Main navigation
-->
<div id="main-navbar" class="navbar navbar-inverse" role="navigation">

    <div class="navbar-inner">
        <!-- Main navbar header -->
        <div class="navbar-header" style="padding-left:0px!important">

            <!-- Logo -->
            <a href="index.html" class="navbar-brand">
                <div><img alt="Pixel Admin" src="/assets/images/pixel-admin/main-navbar-logo.png"></div>
                胡兵
            </a>

            <!-- Main navbar toggle -->
            <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#main-navbar-collapse">
                <i class="navbar-icon fa fa-bars"></i></button>

        </div> <!-- / .navbar-header -->

        <div id="main-navbar-collapse" class="collapse navbar-collapse main-navbar-collapse">
            <div>
                <ul class="nav navbar-nav">
                    <li>
                        <a href="../">订单管理</a>
                    </li>
                    <li class="dropdown">
                        <a href="#" class="dropdown-toggle" data-toggle="dropdown">其它</a>
                        <ul class="dropdown-menu">
                            <li><a href="#">呵呵</a></li>
                            <li><a href="#">滴滴</a></li>
                            <li class="divider"></li>
                            <li><a href="#">乐乐</a></li>
                        </ul>
                    </li>
                    <li>
                        <a href="###" th:onclick="'javascript:exporttable();'">导出excel</a>
                    </li>
                </ul> <!-- / .navbar-nav -->

                <div class="right clearfix">
                    <ul class="nav navbar-nav pull-right right-navbar-nav">

                        <li class="nav-icon-btn nav-icon-btn-danger dropdown">
                            <a href="#notifications" class="dropdown-toggle" data-toggle="dropdown">
                                <span class="label">5</span>
                                <i class="nav-icon fa fa-bullhorn"></i>
                                <span class="small-screen-text">Notifications</span>
                            </a>
                            <script>
                                init.push(function () {
                                    $('#main-navbar-notifications').slimScroll({ height: 250 });
                                });
                            </script>

                            <div class="dropdown-menu widget-notifications no-padding" style="width: 300px">
                                <div class="notifications-list" id="main-navbar-notifications">

                                    <div class="notification">
                                        <div class="notification-title text-danger">SYSTEM</div>
                                        <div class="notification-description"><strong>Error 500</strong>: Syntax error in index.php at line <strong>461</strong>.</div>
                                        <div class="notification-ago">12h ago</div>
                                        <div class="notification-icon fa fa-hdd-o bg-danger"></div>
                                    </div> <!-- / .notification -->

                                </div> <!-- / .notifications-list -->
                                <a href="javascript:void(0)" id="logout">[退出]</a>
                            </div> <!-- / .dropdown-menu -->
                        </li>
                        <li class="nav-icon-btn nav-icon-btn-success dropdown">
                            <a href="#messages" class="dropdown-toggle" data-toggle="dropdown">
                                <span class="label">10</span>
                                <i class="nav-icon fa fa-envelope"></i>
                                <span class="small-screen-text">Income messages</span>
                            </a>

                            <!-- MESSAGES -->

                            <!-- Javascript -->
                            <script>
                                init.push(function () {
                                    $('#main-navbar-messages').slimScroll({ height: 250 });
                                });
                            </script>
                            <!-- / Javascript -->

                            <div class="dropdown-menu widget-messages-alt no-padding" style="width: 300px;">
                                <div class="messages-list" id="main-navbar-messages">

                                    <div class="message">
                                        <img src="/assets/demo/avatars/2.jpg" alt="" class="message-avatar">
                                        <a href="#" class="message-subject">Lorem ipsum dolor sit amet.</a>
                                        <div class="message-description">
                                            from <a href="#">Robert Jang</a>
                                            &nbsp;&nbsp;·&nbsp;&nbsp;
                                            2h ago
                                        </div>
                                    </div> <!-- / .message -->

                                </div> <!-- / .messages-list -->
                                <a href="#" class="messages-link">MORE MESSAGES</a>
                            </div> <!-- / .dropdown-menu -->
                        </li>
                        <!-- /3. $END_NAVBAR_ICON_BUTTONS -->

                        <li class="dropdown">
                            <a href="#" class="dropdown-toggle user-menu" data-toggle="dropdown">
                                <img src="/assets/demo/avatars/1.jpg" alt="">
                                <span>John Doe</span>
                            </a>
                            <ul class="dropdown-menu">
                                <li><a href="#"><span class="label label-warning pull-right">New</span>Profile</a></li>
                                <li><a href="#"><span class="badge badge-primary pull-right">New</span>Account</a></li>
                                <li><a href="#"><i class="dropdown-icon fa fa-cog"></i>&nbsp;&nbsp;Settings</a></li>
                                <li class="divider"></li>
                                <li><a href="/logout"><i class="dropdown-icon fa fa-power-off"></i>&nbsp;&nbsp;Log Out</a></li>
                            </ul>
                        </li>
                    </ul> <!-- / .navbar-nav -->
                </div> <!-- / .right -->
            </div>
        </div> <!-- / #main-navbar-collapse -->
    </div> <!-- / .navbar-inner -->
</div> <!-- / #main-navbar -->
<!-- /2. $END_MAIN_NAVIGATION -->

<form th:action="@{/logout}" method="post" id="logoutform">
</form>

<div id="content-wrapper" style="padding: 46px 0px;">
    <div layout:fragment="content">
        <p>Content goes here...</p>
    </div>
</div>



<!-- Pixel Admin's javascripts -->
<script src="/assets/javascripts/bootstrap.min.js"></script>
<script src="/assets/javascripts/pixel-admin.min.js"></script>


<script src="/assets/javascripts/jquery.table2excel.js"></script>
<script type="text/javascript">
    init.push(function () {

        $("#logout").click(function () {
            if (confirm('您确定退出吗？')) {
                $("#logoutform").submit();
            }
        });

        // Javascript code here
        $('#infotable').dataTable();
        $('.dataTables_filter input').attr('placeholder', '搜索...');
    })
    window.PixelAdmin.start(init);


    $(function () {
        var token = $("meta[name='_csrf']").attr("content");
        var header = $("meta[name='_csrf_header']").attr("content");
        $(document).ajaxSend(function(e, xhr, options) {
            xhr.setRequestHeader(header, token);
        });
    });


    function exporttable(){
        $("table").table2excel({
            exclude: ".noExl",
            name: "Excel Document Name",
            filename: "订单",
            fileext: ".xls",
            exclude_img: true,
            exclude_links: true,
            exclude_inputs: true
        });
    }
</script>
</body>
</html>